package edu.zut;

import java.util.Scanner;

public class calculateAge {
    int year, month, day;

    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int year = scan.nextInt();
        int month = scan.nextInt();
        int day = scan.nextInt();
        int a = 2017 - year;
        int sum = 0;
        if (month < 12)
            System.out.println("age=" + a);
        else if (month == 12 && day < 25) {
            System.out.println("age=" + a);
        } else {
            sum=a+1;
            System.out.println("age=" + sum);
        }
    }
}
